import { useUserStore } from "@/stores/userStore";
import { useAppStore } from "@/stores/appStore";
import router from "../../router";
// 首页的路劲
export const home_path = "/index";
export const home_key = "index";
export const filterRoutes = ["/404", "/loginPage"];

// 退出登录功能
export const logout = () => {
  const user = useUserStore();
  const appStore = useAppStore();
  user.setUserInfo({});
  appStore.removeAllOpenRouter();
  window.localStorage.setItem("accessToken", "");
  router.push("/");
};
